﻿clearForm("formEditor");

document.formEditor.parent_master_tuid.value = "${fld:tuid}";
document.formEditor.project_id.value = "${fld:project_tuid}";
document.formEditor.project_name.value = "${fld:project_name}";
//setCheckboxValue("user_sex","${fld:user_sex}","formEditor");
document.formEditor.cun_name.value = "${fld:cun_name}";
document.formEditor.tun_name.value = "${fld:tun_name}";
//setCheckboxValue("is_local","${fld:is_local}","formEditor");
//setCheckboxValue("is_onechild","${fld:is_onechild}","formEditor");
//setCheckboxValue("single_status","${fld:single_status}","formEditor");
setCheckboxValue("is_touqin","${fld:is_touqin}","formEditor");
document.formEditor.remark.value = "${fld:remark}";
document.formEditor.address.value = "${fld:address}";
document.formEditor.hukoubu_serialno.value = "${fld:hukoubu_serialno}";
document.formEditor.fangzhao_serialno.value = "${fld:fangzhao_serialno}";
document.formEditor.dizhao_serialno.value = "${fld:dizhao_serialno}";
document.formEditor.check_date.value = "${fld:check_date@yyyy-MM-dd}";
document.formEditor.liangfang_remak.value = "${fld:liangfang_remak@js}";

//院内设施金额
document.formEditor.total_fee.value = "${fld:total_fee}";

//正房

document.formEditor.zf_level1.value = "${fld:zf_level1}";
document.formEditor.zf_price1.value = "${fld:zf_price1}";
document.formEditor.zf_level2.value = "${fld:zf_level2}";
document.formEditor.zf_price2.value = "${fld:zf_price2}";

//小房
document.formEditor.xf_level1.value = "${fld:xf_level1}";
document.formEditor.xf_price1.value = "${fld:xf_price1}";
document.formEditor.xf_level2.value = "${fld:xf_level2}";
document.formEditor.xf_price2.value = "${fld:xf_price2}";
document.formEditor.xf_level3.value = "${fld:xf_level3}";
document.formEditor.xf_price3.value = "${fld:xf_price3}";
document.formEditor.xf_level4.value = "${fld:xf_level4}";
document.formEditor.xf_price4.value = "${fld:xf_price4}";
document.formEditor.xf_level5.value = "${fld:xf_level5}";
document.formEditor.xf_price5.value = "${fld:xf_price5}";
document.formEditor.xf_level6.value = "${fld:xf_level6}";
document.formEditor.xf_price6.value = "${fld:xf_price6}";

//单价赋值（除了正房小房）
policyValue();

setArray(new Array("${fld:p_zf_number1}","${fld:zf_area1}","${fld:p_zf_number2}","${fld:zf_area2}","${fld:p_xf_area1}","${fld:p_xf_area2}",
						"${fld:p_xf_area3}","${fld:p_xf_area4}","${fld:p_xf_area5}","${fld:p_xf_area6}",
						"${fld:p_dijiao}","${fld:p_shu}","${fld:p_shuijin_shouya}","${fld:p_shuijin_qita}",
						"${fld:p_chuqinshepeng}","${fld:p_guoshu}","${fld:p_zhaoqichi}","${fld:p_yuanqiang}",
						"${fld:p_zhujuan}","${fld:p_zilaishui}","${fld:p_cesuo}","${fld:p_shuinishe}",
						"${fld:p_dianhua}","${fld:p_youxiandianshi}","${fld:p_menlou_yi}","${fld:p_menlou_er}",
						"${fld:p_fengbiyuanqiangmen}","${fld:p_banfengbiyuanqiangmen}","${fld:p_teshuguoshu_l1}",
						"${fld:p_teshuguoshu_l2}","${fld:p_teshuguoshu_l3}","${fld:p_teshuguoshu_l4}",
						"${fld:p_teshuguoshu_l5}"));

//选择新户主
document.formEditor.master_tuid.options.length = 0;
option = new Option("请选择");
option.value = "";
document.formEditor.master_tuid.options.add(option);
<qrows>
option = new Option("${fld:s_name}");
option.value = "${fld:s_tuid}";
document.formEditor.master_tuid.options.add(option);
</qrows>

document.forms["formEditor"].elements["deleteCommand"].style.display='none';
document.getElementById("divEditor").style.display='';
